package com.zrs.gmall.product.controller;

import com.zrs.gmall.common.result.Result;
import com.zrs.gmall.product.service.BaseSaleAttrService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ZhaoRuiSheng
 * @create 2023/2/22 20:32
 */
@Api(tags = "基本销售属性")
@RestController
@RequestMapping("/admin/product")
public class BaseSaleAttrController {

    @Autowired
    private BaseSaleAttrService baseSaleAttrService;

    /**
     * 查询平台所有的销售属性名称
     * @return
     */
    @ApiOperation(value = "查询平台所有的销售属性名称")
    @GetMapping("/baseSaleAttrList")
    public Result getBaseSaleAttrList(){
        return Result.ok(baseSaleAttrService.list());
    }


}
